package com.lara;

import java.util.ArrayList;
import java.util.ListIterator;

public class Manager36 {
public static void main(String[] args) {
	ArrayList list=new ArrayList();
	list.add(9);
	list.add(0);
	list.add(5);
	list.add(5);
	list.add(4);
	list.add(19);
	ListIterator lit=list.listIterator();
	while(lit.hasNext()){
		System.out.print(lit.next()+",");
	}
	System.out.println();
	System.out.println("--------");
	while(lit.hasPrevious()){
		System.out.print(lit.previous()+",");
	}
}
}
